import Sequelize from 'sequelize';
import db from 'utils/db';

const model = db.define('user', {
  id: {
    type: Sequelize.INTEGER,
    primaryKey: true,
    autoIncrement: true
  },
  title: {
    type: Sequelize.STRING,
    unique: true
  },
  description: Sequelize.TEXT,
  content: Sequelize.TEXT,
}, {
  tableName: 'posts'
})

model.sync();
export default model